// ******************************************************************
// * Copyright(c)  Steven Lu
// * Description   : Entity_SALES_CONTRACT_ITEM
// * CreateDate    : 2011/8/16 10:16:41
// * Creater       : CodeSmith
// * LastChangeDate: 2011/8/16 10:16:41
// * LastChanger   : 2011/8/16 10:16:41
// * Version Info  : 1.0 For ESOL
// ******************************************************************

using System;
using System.Data;
using System.Collections.Generic;
using System.Text;
using Suzsoft.Smart.EntityCore;
using ESOL.Common.Schema;

namespace ESOL.Common.Entity
{
	[Serializable]
	public partial class SalesContractItemEntity : EntityBase
    {
        public SalesContractItemTable TableSchema
        {
            get
            {
                return SalesContractItemTable.Current;
            }
		}
		
		public SalesContractItemEntity()
        {

        }
		
		public SalesContractItemEntity(DataRow dr)
        {
			if(dr == null)
			{
				return;
			}
			this.ContractItemId = Convert.ToString(CommonFunctions.ToObject(dr["CONTRACT_ITEM_ID"]));
			this.ContractId = Convert.ToString(CommonFunctions.ToObject(dr["CONTRACT_ID"]));
			this.QuoteItemId = Convert.ToString(CommonFunctions.ToObject(dr["QUOTE_ITEM_ID"]));
        }
		
		public SalesContractItemEntity(DataRowView dr)
        {
			if(dr == null)
			{
				return;
			}
			this.ContractItemId = Convert.ToString(CommonFunctions.ToObject(dr["CONTRACT_ITEM_ID"]));
			this.ContractId = Convert.ToString(CommonFunctions.ToObject(dr["CONTRACT_ID"]));
			this.QuoteItemId = Convert.ToString(CommonFunctions.ToObject(dr["QUOTE_ITEM_ID"]));
        }

        public override TableInfo OringTableSchema
        {
            get
            {
                return SalesContractItemTable.Current;
            }
        }
		
		#region Perporty List
        public string ContractItemId
        {
            get { return Convert.ToString(GetData(SalesContractItemTable.C_CONTRACT_ITEM_ID)); }
            set { SetData(SalesContractItemTable.C_CONTRACT_ITEM_ID, value); }
        }
		
        public string ContractId
        {
            get { return Convert.ToString(GetData(SalesContractItemTable.C_CONTRACT_ID)); }
            set { SetData(SalesContractItemTable.C_CONTRACT_ID, value); }
        }
		
        public string QuoteItemId
        {
            get { return Convert.ToString(GetData(SalesContractItemTable.C_QUOTE_ITEM_ID)); }
            set { SetData(SalesContractItemTable.C_QUOTE_ITEM_ID, value); }
        }
		
		#endregion
	}
	
	
}	

